|
Michael Schäuble wrote: From the information I had before, it seemed that I would have to register my dll with regasm on every computer before I could use it.
Yes.
Michael Schäuble wrote: As a consequence I would have to install the .net framework on each machine, just to allow Excel recognize my assembly.
If you wrote it in VB.NET, you have no choice but to install the corresponding .NET Framework.
Michael Schäuble wrote: After an experiment I figure now that it seems to be possible to deploy a pre-produced .tlb file as well - Excel called my dll properly on that particular computer. So I might probably save the whole regasm story as well as the installation of the .net framework.
Nope. The .TLB (type library) file is just the COM registration info. It doesn't contain any executable code. You STILL have to install the .NET Framework to run the Add-In code you wrote in VB.NET and you still need the .DLL file you built.
|
|
|
|
|
Too sad... Still thank you, Dave.
|
|
|
|
|
Hi,
I am modeling a vb net windows ce application, and i have to use a web services.
How can i change the adresses of the web services dynamically ?
The url behavior is set to dynamically.
in the constructor i give my adresses :
Public Sub New(ByVal pvalue As String)
Me.Url = pvalue
End Sub
But it doesn't carre about my pvalue adresses, it always take the adress i give the first time...how can i make this dynamic ???
THANKS
|
|
|
|
|
How could I get the file name or path of an image file displayed in a DataGridViewImageCell by clicking on the Cell...?
|
|
|
|
|
I am slightly confused by your question.
If you put the image into the DataGridView, then surely you know the path/filename.
If the image came from a database then it does not have a path.
Henry Minute
Do not read medical books! You could die of a misprint. - Mark Twain
Girl: (staring) "Why do you need an icy cucumber?"
“I want to report a fraud. The government is lying to us all.”
Why do programmers often confuse Halloween and Christmas? - Because 31 Oct = 25 Dec.
Business Myths of the Geek #4 'What you think matters.'
|
|
|
|
|
If the image came from a database, either you database stored the path and you haven't retrieved it, or it stored the image itself, in which case, there is no path since it's not stored as a file anywhere.
If you built the dataset yourself from image files, you just need to add the path to the file you used to another column in the dataset.
|
|
|
|
|
Any one out there should help me.
My project is on bluetooth communication. So i want to write a VB.net application that can communicate with the a mobile phone through bluetooth.
|
|
|
|
|
Yes, anyone should definitely help you...
|
|
|
|
|
... and?
You haven't asked a question, so how is anyone supposed to help you??
|
|
|
|
|
Try searching Google for "Bluetooth VB.NET", I expect there are lots of samples out there.
It's time for a new signature.
|
|
|
|
|
|
Hi,
I am using a scanner , that scaner raise an event when scanning a data .
I have got a function listening this event and when the event is raised, it launch a form.
<br />
private sub INIT()<br />
addhandler scandone, addressof afficherForm<br />
end sub<br />
<br />
<br />
<br />
Private sub scan ()<br />
raiseEvent ScanDone<br />
end sub<br />
<br />
<br />
Private sub AfficherForm() <br />
Dim myform as new form<br />
myform.showdialog<br />
end sub<br />
the problem is, i can't scan anymore when my event is raised and while ma new form is running, i have to exit the "new thread" to be able to scan again.
How can i resolve this problem please ?
thanks
|
|
|
|
|
There's not enough here to determine what your actually doing with these pieces of code (like the form you launched), but the most obvious reason why would be that ShowDialog is a blocking call. No other code will execute until that dialog is dismissed. If this is not what you want, change the ShowDialog to Show. Show does not block. The code after it will continue to execute with the new form still showing.
As a side, whenever you show a form with ShowDialog, you are also responsible for calling Dispose on it when you're done with it. Your code doesn't do that anywhere and will leak resources if it's not fixed.
|
|
|
|
|
For some other reason i have to use the ShowDialog mode.
But i guess it is possible to launch the new form not in the thread that launch the event but from the one of the main form.
It blocks because the form is launched from the scanner thread so the scanner is bloqued.
How can i resolve this ?
|
|
|
|
|
The scanner is using a background thread internally. The library is raising the events on the UI (start up) thread. It may be possible to move the scanner component to a background thread also, but you may also run into problems with that. The people who can answer that question are the people who made the scanner and its SDK.
thesum wrote: But i guess it is possible to launch the new form not in the thread that launch the event but from the one of the main form.
You cannot launch forms on anything other that the startup thread. SO, you have another problem. You cannot launch a new form for every scanned page while the first one is still active. You cannot show form after form after form from that event handler because ShowDialog will block and prevent the handler from executing again until the dialog is dismissed. You simply have not choices here. You have to change the design of your app, specifically, change the ShowDialog to Show.
|
|
|
|
|
Yes i understand, but i would like to launch the form from the starup thread and before making my showdilog i would make a removeHandler for my scanner Event.
One solution is to create a timer.
Enable the timer when the scan is done, and in the Time_Tick event, launch my new form (and removeHandler of my scanner).
There are no other way to do this method by other way than using a Timer ?
|
|
|
|
|
thesum wrote: Enable the timer when the scan is done, and in the Time_Tick event, launch my new form
So you're trying to launch the new form on a seperate thread? Not going to work and is pointless.
The whole point behind a ShowDialog call is to stop execution of the code until the dialog is dismissed. Why are you saying that you need to use ShowDialog, but yet not block the code?
|
|
|
|
|
How to read the contents of a PDF in VB.Net
|
|
|
|
|
|
I am using visual studio 2005, 2008.
And now i am converting visual basic6.0 to vb.net.
Strptr function don't be convertet.
So how can i convert?
below is source.
Public Function AToW(ByVal st As String)
Dim pwz As Integer
pwz = StrPtr(st)
hi
My english is a little.
anyway, nice to meet you~~
and give me your advice anytime~
|
|
|
|
|
|
Hi mates,
I have an unbound datagridview which has bound combobox and an insert button for inserting new row.
The problem is when I input data in row 1 it will move to row 3
after hitting enter key.
Example.
--------------------------------------
column1 | column2(boundcombox)
--------------------------------------
row1 | ----> inserted row
--------------------------------------
row2 | ----> inserted row
--------------------------------------
row3 test | 112 ---->original row
--------------------------------------
Note: I have an event that will automatically
fill the data in column2, when input in column1.
C# コードMicrosoft End User
2000-2008
「「「「「「「「「「「「「「「「「「「「「「「「「「「「
The best things in life are free
」」」」」」」」」」」」」」」」」」」」」」」」」」」」
|
|
|
|
|
Can you show us the code you used to insert the row?
|
|
|
|
|
Heres the code for inserting a new row, it will insert in the middle of two rows, it just NOT insert at the last. it will insert any row you want.
then recount the sequence no.
Private Sub btnInsRow_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnInsRow.Click
Dim posRow, seq As Integer
Dim iRow As Integer
Dim dRow As DataRow = dttable.NewRow
Try
If Me.C1tdbgridAnalyze.RowCount <> 0 Then
If Me.C1tdbgridAnalyze.Item(Me.C1tdbgridAnalyze.Row, 4) < 96 Then
With Me.C1tdbgridAnalyze
dRow("OrderNo") = .Item(.Row, 0)
dRow("ItemNo") = .Item(.Row, 1)
If .Row = 0 Then
posRow = .Row
dRow("SeqNo") = .Item(.Row, 4)
seq = dRow("SeqNo")
Else
posRow = .Row + 1
dRow("SeqNo") = .Item(.Row, 4) + 1
seq = dRow("SeqNo")
End If
dttable.Rows.InsertAt(dRow, posRow)
.Row = posRow
.DirectionAfterEnter = C1.Win.C1TrueDBGrid.DirectionAfterEnterEnum.MoveDown
.Col = 0
.Select()
iRow = seq
For seqRow As Integer = 0 To .RowCount
If seqRow >= posRow Then
If .Item(seqRow, 4) <> Nothing Then
.Item(seqRow, 4) = iRow
End If
iRow += 1
End If
Next
End With
End If
End If
Catch ex As Exception
log.Debug(ex.ToString)
Throw ex
End Try
End Sub
C# コードMicrosoft End User
2000-2008
「「「「「「「「「「「「「「「「「「「「「「「「「「「「
The best things in life are free
」」」」」」」」」」」」」」」」」」」」」」」」」」」」
|
|
|
|
|
C#Coudou wrote: Me.C1tdbgridAnalyze.RowCount <> 0
I would personally not check for 0 rows, but test for less than or equal to 0 ie <=0
C#Coudou wrote: For seqRow As Integer = 0 To .RowCount
Will .RowCount not exceed the bounds for a 0 based collection, should it not be .RowCount - 1
You are more than just interacting with a unbound datagrid here, should you not first start with the insert operation and then update the other controls. e.g. dttable, c1tbdgridAnalyze
C#Coudou wrote: posRow = .Row + 1
You then try to insert at position posRow, this is outwith the bounds of the rows collection as this position does not insert exist, if you are on the last row, do you not need to use an AddRow method (not sure exactly which type of control you are using. are you using a standard System.Windows.Forms.DataGridView?
A standard DGV has both an Rows.Add() and a Rows.Insert(position) method for working with the rows collection.
|
|
|
|